﻿using System;
using System.Linq;
using System.Collections.Generic;
using System.Text;

namespace FetionLite
{
    public enum LoginState
    {
        FX_LOGIN_CONNECTING = FxEvent.FX_EVENT_BASE + 0x0001, //连接服务器
        FX_LOGIN_WAIT_AUTH = FxEvent.FX_EVENT_BASE + 0x0002, //等待认证
        FX_LOGIN_AUTH_OK = FxEvent.FX_EVENT_BASE + 0x0003, //认证成功
        FX_LOGIN_FAIL = FxEvent.FX_EVENT_BASE + 0x0004, //登陆失败
        FX_LOGIN_NETWORK_ERROR = FxEvent.FX_EVENT_BASE + 0x0005, //网络错误
        FX_LOGIN_UNKOWN_ERROR = FxEvent.FX_EVENT_BASE + 0x0006, //未知错误
        FX_LOGIN_UNKOWN_USR = FxEvent.FX_EVENT_BASE + 0x0007, //用户不存在
        FX_LOGIN_GCL_GETTING = FxEvent.FX_EVENT_BASE + 0x0008, //正在获取联系人列表
        FX_LOGIN_GCL_OK = FxEvent.FX_EVENT_BASE + 0x0009,//获取联系人列表成功
        FX_LOGIN_GCL_FAIL = FxEvent.FX_EVENT_BASE + 0x000A, //获取联系人列表失败
        FX_LOGIN_GP_GETTING = FxEvent.FX_EVENT_BASE + 0x000B,//正在获取联系人状态
        FX_LOGIN_GP_OK = FxEvent.FX_EVENT_BASE + 0x000C,//获取联系人状态成功
        FX_LOGIN_GP_FAIL = FxEvent.FX_EVENT_BASE + 0x000D, //获取联系人状态失败
        FX_LOGIN_OK = FxEvent.FX_EVENT_BASE + 0x000E, //登陆成功
        FX_LOGIN_TIMEOUT = FxEvent.FX_EVENT_BASE + 0x000F, //登陆超时 ? need it.. have a UNKOWN_ERROR
        FX_LOGIN_URI_ERROR = FxEvent.FX_EVENT_SPARE + 0x0001, //login fail of get the user's uri fail
        FX_LOGIN_SERVER_ERROR = FxEvent.FX_EVENT_SPARE + 0x0002, //
        FX_LOGIN_SERVER_REFUSE = FxEvent.FX_EVENT_SPARE + 0x0003, //fetion server refuse, you should relogin again
        FX_LOGIN_GSML_OK = FxEvent.FX_EVENT_SPARE + 0x0004, //get schedule sms list ok
        FX_LOGIN_GSML_FAIL = FxEvent.FX_EVENT_SPARE + 0x0005 //get schedule sms list fail
    }

    public enum FxMessage
    {
        FX_NEW_MESSAGE = FxEvent.FX_EVENT_BASE + 0x0010,
        FX_ACCOUNT_UPDATA_OK = FxEvent.FX_EVENT_BASE + 0x0050
    }

    public enum FetionUserType
    {
        FTION_UTYPE_UNSET = 0,        //未设置 
        FTION_UTYPE_PC,               //PC用户，已经注册fetion 
        FTION_UTYPE_MOBLIE            //手机用户，未注册fetion 
    }

    public class FetionGroup
    {
        public int Id
        {
            get;
            set;
        }

        public string Name
        {
            get;
            set;
        }
    }

    public class FetionPersonal
    {
        /// <summary>
        /// 昵称
        /// </summary>
        public string NickName { get; set; }
        /// <summary>
        /// 心情
        /// </summary>
        public string Impresa { get; set; }
        /// <summary>
        /// 性别 1 boy 0 girl
        /// </summary>
        public int Gender { get; set; }
        /// <summary>
        /// 国家
        /// </summary>
        public string Nation { get; set; }
        /// <summary>
        /// 州
        /// </summary>
        public string Province { get; set; }
        /// <summary>
        /// 城市编号，需要测试
        /// </summary>
        public int City { get; set; }
        public int IvrEnabled { get; set; }
        public int PortraitCRC { get; set; }
        public int Provisoning { get; set; }
        /// <summary>
        /// 手机号码
        /// </summary>
        public string MobileNo { get; set; }
        /// <summary>
        /// 名称
        /// </summary>
        public string Name { get; set; }
        /// <summary>
        /// 生日
        /// </summary>
        public string Birthday { get; set; }
        /// <summary>
        /// 生日是否有效？？
        /// </summary>
        public int BirthdayValid { get; set; }
        /// <summary>
        /// 农历生肖
        /// </summary>
        public int LunarAnimal { get; set; }
        public int Horoscope { get; set; }
        public string Profile { get; set; }
        public int BloodType { get; set; }
        public string Occupation { get; set; }
        public string Hobby { get; set; }
        public string PersonalEmail { get; set; }
        public string WorkEmail { get; set; }
        public string OtherEmail { get; set; }
        public int PrimaryEmail { get; set; }
        public string JobTitle { get; set; }
        public string HomePhone { get; set; }
        public string WorkPhone { get; set; }
        public string OtherPhone { get; set; }
        public string Company { get; set; }
        public string CompanyWebSite { get; set; }
        public int MatchEnabled { get; set; }
        public int RefuseSMSDay { get; set; }
    }

    public class FetionAccount
    {
        public int Id { get; set; }

        public string Uri { get; set; }

        public string LocalName { get; set; }

        public string BuddyLists { get; set; }

        public int GroupId { get; set; }

        public int RelationStatus { get; set; }

        public int OnlineNotify { get; set; }

        public int StatusCode { get; set; }

        public int OnlineStatus { get; set; }

        public int PortraitCRC { get; set; }

        public FetionPersonal Personal { get; set; }

        public FetionUserType UserType { get; set; }

        public string DeviceType { get; set; }
    }
}
